package com.ruoyi.purchase.service.impl;

import java.util.List;

import com.ruoyi.purchase.mapper.FirmInventoryMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.purchase.domain.FirmInventory;
import com.ruoyi.purchase.service.IFirmInventoryService;

/**
 * 库存管理Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-07-16
 */
@Service
public class FirmInventoryServiceImpl implements IFirmInventoryService 
{
    @Autowired
    private FirmInventoryMapper firmInventoryMapper;

    /**
     * 查询库存管理
     * 
     * @param id 库存管理主键
     * @return 库存管理
     */
    @Override
    public FirmInventory selectFirmInventoryById(Long id)
    {
        return firmInventoryMapper.selectFirmInventoryById(id);
    }

    /**
     * 查询库存管理列表
     * 
     * @param firmInventory 库存管理
     * @return 库存管理
     */
    @Override
    public List<FirmInventory> selectFirmInventoryList(FirmInventory firmInventory)
    {
        return firmInventoryMapper.selectFirmInventoryList(firmInventory);
    }

    /**
     * 新增库存管理
     * 
     * @param firmInventory 库存管理
     * @return 结果
     */
    @Override
    public int insertFirmInventory(FirmInventory firmInventory)
    {
        return firmInventoryMapper.insertFirmInventory(firmInventory);
    }

    /**
     * 修改库存管理
     * 
     * @param firmInventory 库存管理
     * @return 结果
     */
    @Override
    public int updateFirmInventory(FirmInventory firmInventory)
    {
        return firmInventoryMapper.updateFirmInventory(firmInventory);
    }

    /**
     * 批量删除库存管理
     * 
     * @param ids 需要删除的库存管理主键
     * @return 结果
     */
    @Override
    public int deleteFirmInventoryByIds(Long[] ids)
    {
        return firmInventoryMapper.deleteFirmInventoryByIds(ids);
    }

    /**
     * 删除库存管理信息
     * 
     * @param id 库存管理主键
     * @return 结果
     */
    @Override
    public int deleteFirmInventoryById(Long id)
    {
        return firmInventoryMapper.deleteFirmInventoryById(id);
    }
}
